<?php 
$url_edit_available_time = $this->url(array('module'=>"",'controller'=>"available-time",'action'=>"edit-time"),null,true);
$tr = Application_Form_FrmLanguages::getCurrentlanguage();
$session_user=new Zend_Session_Namespace('auth');
$request=Zend_Controller_Front::getInstance()->getRequest();
$user_info = new Application_Model_DbTable_DbGetUserInfo();
$result = $user_info->getUserInfoteacher();
$profiles = $this->profile_teacher;
?>
<!DOCTYPE html>
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">
    <title>Schedule Western</title>
    <!-- Bootstrap core CSS -->
    <link href="<?php echo $this->baseUrl()?>/css/bootstrap.css" rel="stylesheet">
	<link href="<?php echo $this->baseUrl(); ?>/css/font-awesome.min.css" rel="stylesheet">
	<link href="<?php echo $this->baseUrl()?>/css/layout.css" rel="stylesheet">
	<link href="<?php echo $this->baseUrl(); ?>/css/font-awesome.css" rel="stylesheet">
    <!-- Add custom CSS here -->
    <link href="<?php echo $this->baseUrl(); ?>/css/sb-admin.css" rel="stylesheet">
    <link rel="stylesheet" href="<?php echo $this->baseUrl(); ?>/font-awesome/css/font-awesome.min.css">
    <!-- Page Specific CSS -->
    <!-- get for select auto complete chosen.jquery.js-->
		<script type="text/javascript" src="<?php echo $this->baseUrl();?>/test/chosen.jquery.js"></script>
		<link rel="stylesheet" media="screen" href="<?php echo $this->baseUrl();?>/css/chosen.css" type="text/css" />
		<style type="text/css">
#user_profile{
margin: 0 auto;
float: left;
}
#information{
}
#user_profile_2{
border-color: #eee;
width: 100%;
margin: 0 auto;
}
#page-wrapper {
padding: 2px 0px;
background: #FFF;
width: 70%;
margin: 0 auto;
border-radius: 0px 0px 3px 3px;
margin-bottom: 5px;
box-shadow: 0px 0px 13px #8A8A8A;
}
#user_profile {
margin: 0 auto;
float: left;
width: 270px;
}
		</style>
  </head>
<body>
    <div id="wrapper">
       <!-- Sidebar -->
      <!-- Sidebar -->
      <nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
        <!-- Brand and toggle get grouped for better mobile display -->
        <div class="navbar-header">
          <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-ex1-collapse">
            <span class="sr-only">Toggle navigation</span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </button>
         <a style="border: 0; " class="navbar-brand" href="<?php echo $this->baseUrl(); ?>/index/teachers">
			<div style="text-align: center; color: #FFF; font-weight: bold; font-size: 25px; margin: -4px 0px -6px 0px;">Western University
				<img style="height: 48px; padding: 0; margin-left: 5px; margin-right: 5px;" src="<?php echo $this->baseUrl(); ?>/images/bg_logo.png" width="30"/>
			</div>
		  </a>
        </div>
		<div class="collapse navbar-collapse navbar-ex1-collapse">  
          <ul class="nav navbar-nav navbar-left navbar-user" id="side-menu">
          	<li class="dropdown user-dropdown">
              <a href="<?php echo $this->baseUrl(); ?>/index/teachers" class="dropdown-toggle"><i class="icon-calendar"></i> General of Teacher </a>
            </li>
            <li class="dropdown user-dropdown">
              <a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="icon-calendar"></i> Personal Schedule </a>
            </li>
            <li class="dropdown user-dropdown">
              <a href="<?php echo $this->baseUrl();?>/available-time/add-avaliable" class="dropdown-toggle"><i class="icon-calendar"></i> Add Available Time </a>
            </li>
          </ul>
          <ul class="nav navbar-nav navbar-right navbar-user">          	
           <li class="dropdown">
	          <a class="dropdown-toggle" data-toggle="dropdown" href="#">
	            <i class="fa fa-user fa-fw"></i> <?php echo ucwords(strtolower($session_user->username));?>&nbsp;&nbsp;<i class="fa fa-caret-down"></i>
	          </a>
	          <ul class="dropdown-menu dropdown-user">
	             <li><a href="<?php echo $this->baseUrl(); ?>/index/profileteachers"><i class="fa fa-user fa-fw"></i> User Profile</a></li>
	             <li><a href="<?php echo $this->url(array('module'=>'','controller'=>'index','action'=>'edit-teacher', 'id'=>$session_user->teacher_id));?>"><i class="fa fa-gear fa-fw"></i> Edit Profile</a></li>
	             <li class="divider"></li>
	             <li><a href="<?php echo $this->url(array('module'=>'','controller'=>'index','action'=>'logout', 'value'=>1));?>"><i class="fa fa-sign-out fa-fw"></i> Logout</a></li>
	          </ul>
        	<!-- /.dropdown-user -->
     		</li>
          </ul>
        </div><!-- /.navbar-collapse -->
      </nav>
<div id="warpper_1" class="col-lg-12">
<div id="page-wrapper">		
   <div class="panel-heading" style="margin: 0 auto; width: 95%; padding: 10px 0px;">    	  
        	  <h2 style=" color: #38A3D6; border-bottom: 5px solid #38A3D6; padding: 12px 0px; margin: -10px 0px 15px 0px;">
        	  Profile Teacher
        	  </h2>
   </div>	
		<div class="Wap_form" style=" width: 95%; margin: 0 auto; margin-bottom: 20px;">
				<?php if($profiles['photo']==""){?>
				<img width="180px" alt="" src="<?php echo $this->baseUrl();?>/images/images_profile.jpg" style="float: left; margin: 0px 5% 0px 0px;">
				<?php }else {?>
				<img width="180px" alt="" src="<?php echo $this->baseUrl();?>/images/fi-upload/<?php echo $profiles['photo'];?> " style="float: left; margin: 0px 5% 0px 0px;">
				<?php }?>
		<form action="#" >
				<div id="information">
					<div id="user_profile" style="margin-right: 60px;">
					<table>
					<?php //foreach ($profiles as $profiless){?>
						<tr>
							<td colspan="2"><h4>Contact Information</h4></td>
						</tr>
						<tr>
							<td>Email : </td>
							<td ><?php echo $profiles['email'];?></td>
						</tr>
						<tr>
							<td width="47%">Phone Number :</td>
							<td><?php echo $profiles['tel'];?></td>
						</tr>
						<tr>
							<td>Address :</td>
							<td><?php echo $profiles['address'];?></td>
						</tr>
					</table>
					</div>
					<div id="user_profile">
					<table>
						<tr>
							<td colspan="2"><h4>General Information</h4></td>
						</tr>
						<tr>
							<td width="60%">User Name :</td>
							<td><?php echo $profiles['teacher_name'];?></td>
						</tr>
						<tr>
							<td>ID :</td>
							<td><?php echo $profiles['id_code'];?></td>
						</tr>
						<tr>
							<td>Education :</td>
							<?php error_reporting(0); $edu_teacher = $this->edu_teacher;?>
							<td><?php foreach ($edu_teacher as $edu_teachers){echo $edu_teachers['ed_name']." , ";};?> / </td>
						</tr>
						<tr>
							<td>Subject :</td>
							<?php error_reporting(0); $subjects = $this->Subject_teacher;?>
							<td><?php foreach ($subjects as $subject){echo $subject['subject_name']." , ";};?></td>
						</tr>
						<tr>
							<td>Skill :</td>
							<?php error_reporting(0);  $skill = $this->Skill_teacher;?>
							<td><?php foreach ($skill as $skills){ echo $skills['skill']." , ";};?></td>
						</tr>
						<tr>
							<td>Possition :</td>
							<td><span style="padding:5px 10px; color:#fff; background: #287DFD;-webkit-border-radius: 5px;-moz-border-radius: 5px;border-radius: 5px;">
							<?php //echo $profiles['user_type'];?>Teacher</span>
							</td>
						</tr>
						</table>
						</div>
						<?php //}?>
					</table>					
				</div>
		</form>
		<div id="user_profile_2" style="float: left;">
	</div>
	<div style="clear: both;"></div>
</div>
</div>
</div>
<div class="banner-footer">
	<img src="<?php echo $this->baseUrl(); ?>/images/banner/banner.jpg" />
 </div> 
 
 <div class="footer">
            Address: #15, Street 528, Sangkat Boeungkok I, Khan Toul Kork, Phnom Penh, CAMBODIA.<br />
            Tell: 023 998 233, Email: <a href="mailto://info_wu@western.edu.kh">info_wu@western.edu.kh</a>, Website: <a href="http://www.western.edu.kh" target="_blank">www.western.edu.kh</a>
 </div>
</div>
</body>
<div style="clear: both;"></div>
<script src="<?php echo $this->baseUrl(); ?>/js/jquery.min.js"></script>
<script src="<?php echo $this->baseUrl(); ?>/js/bootstrap.js"></script>
<!-- Page Specific Plugins -->
<script src="<?php echo $this->baseUrl(); ?>/js/raphael-min.js"></script>
<script src="<?php echo $this->baseUrl(); ?>/js/morris-0.4.3.min.js"></script>
<script src="<?php echo $this->baseUrl(); ?>/js/morris/chart-data-morris.js"></script>
<script src="<?php echo $this->baseUrl(); ?>/js/tablesorter/jquery.tablesorter.js"></script>
<script src="<?php echo $this->baseUrl(); ?>/js/tablesorter/tables.js"></script>
<script type="text/javascript" src="<?php echo $this->baseUrl()?>/js/jquery-1.7.2.min.js"></script>
<script src="<?php echo $this->baseUrl()?>/js/validation/languages/jquery.validationEngine-en.js" type="text/javascript" charset="utf-8"></script>
<link type="text/css" rel="stylesheet" media="screen" href="<?php echo $this->baseUrl()?>/js/validation/validationEngine.jquery.css">
<script src="<?php echo $this->baseUrl()?>/js/validation/jquery.validationEngine.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript" src="<?php echo $this->baseUrl()?>/js/jquery-ui-1.8.20.custom.min.js"></script>
<link type="text/css" href="<?php echo $this->baseUrl()?>/css/custom-theme/jquery-ui-1.8.20.custom.css" rel="stylesheet" />	
<script type="text/javascript">
$(function(){				
	$("#frm").validationEngine();
});
</script>